CREATE EXTERNAL TABLE jms_dm.dm_network_unbagging_detail_dt(
  date_time date COMMENT '日期', 
  region_code string COMMENT '大区编码', 
  region_name string COMMENT '大区名称', 
  proxyarea_code string COMMENT '代理区编码', 
  proxyarea_name string COMMENT '代理区名称', 
  franchisees_code string COMMENT '加盟商编码', 
  franchisees_name string COMMENT '加盟商名称', 
  site_code string COMMENT '网点编码', 
  site_name string COMMENT '网点名称', 
  waybill_no string COMMENT '单号', 
  customer_code string COMMENT '客户编码', 
  customer_name string COMMENT '客户名称', 
  goods_type_code string COMMENT '物品类型编码', 
  goods_type_name string COMMENT '物品类型名称', 
  package_length decimal(16,2) COMMENT '长', 
  package_wide decimal(16,2) COMMENT '宽', 
  package_high decimal(16,2) COMMENT '高', 
  package_charge_weight decimal(16,2) COMMENT '重量', 
  end_center_code string COMMENT '末端机构code', 
  end_center_name string COMMENT '末端机构name', 
  order_source_code string COMMENT '订单来源code', 
  order_source_name string COMMENT '订单来源name')
COMMENT '应建未建票数明细'
 PARTITIONED BY (dt STRING COMMENT '时间分区 发件时间')
    STORED AS PARQUET
    LOCATION '/dw/hive/jms_dm.db/external/dm_network_unbagging_detail_dt'
    TBLPROPERTIES (
        'discover.partitions' = 'false',
        'parquet.column.index.access' = 'true'
        );